import java.util.Scanner;
import java.util.regex.Pattern;

// HJ12 字符串反转
public class HJ12 {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        while (sc.hasNext()) {
            String str = sc.nextLine();
            if(str.matches("^[a-z]*$")){
                System.out.println(new StringBuilder(str).reverse().toString());
            }
        }
    }
}
